---
layout: example.html
title: Loading Spinner
shortdesc: Example using load events to show a loading spinner.
docs: >
  You can listen for the map's <code>loadstart</code> and <code>loadend</code> events
  to show a loading spinner on top of the map.
tags: "events, loading, spinner"
cloak:
  - key: get_your_own_D6rA4zTHduk6KOKTXzGB
    value: Get your own API key at https://www.maptiler.com/cloud/
---
<div id="map" class="map"></div>
